package org.example.redo.listener;

import org.example.redo.constant.Constants;
import org.springframework.amqp.rabbit.annotation.Queue;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
public class WorkListener {
    @RabbitListener(queues = Constants.WORK_QUEUE)
    public void receiveWork(String message) {
        System.out.println("收到消息:"+message);
    }
}
